package com.wing.sell.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wing.sell.model.entity.DeliveryRecord;
import com.wing.sell.model.request.DeliveryRecordForm;
import com.wing.sell.model.response.DeliveryRecordVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 交付记录表-Dao
 *
 * @author
 */
@Mapper
public interface DeliveryRecordDao extends BaseMapper<DeliveryRecord> {

    /**
     * 列表-app
     *
     * @param params
     *
     * @return
     */
    List<DeliveryRecordVO> list4app(@Param("params") Map<String, Object> params);

    /**
     * 分页列表-app
     *
     * @param page
     * @param params
     *
     * @return
     */
    List<DeliveryRecordVO> list4app(@Param("page") Page<DeliveryRecordVO> page, @Param("params") Map<String, Object> params);

    /**
     * 详情-app
     *
     * @param id
     *
     * @return
     */
    DeliveryRecordVO get4appById(Long id);

    /**
     * 交付记录分页列表
     *
     * @param page
     * @param params
     *
     * @return
     */
    List<DeliveryRecordVO> deliveryRecordList(@Param("page") Page<DeliveryRecordVO> page, @Param("params") Map<String, Object> params);

    /**
     * 订单信息列表
     *
     * @param params
     *
     * @return
     */
    List<DeliveryRecordVO> saleOrderList(@Param("params") Map<String, Object> params);

    /**
     * 编号查询信息
     * @param code
     * @return
     */
    DeliveryRecordVO getInfoByCode(String code);

    /**
     * 查询详情
     * @param id
     * @return
     */
    DeliveryRecordForm getDetailBy(@Param("id") Long id);
}
